package library;

import com.gooddies.swing.hList;
import java.util.List;
import library.database.Data;
import library.model.Author;

/**
 * @author sad
 */
public class AuthorsList extends hList<Author> {

    public void setAuthorList(List<Author> authors) {
        clearItems();
        addItems(authors.toArray(new Author[0]));
    }
    
    public void setAuthorList(Author[] authors) {
        clearItems();
        addItems(authors);
    }
    
    public void fillAuthorsListFull(){
        Author[]authors=Data.getAuthors();
        setAuthorList(authors);
    }
}